package com.kfyang.manualgear.generator.impl.jdbc.constant;

import com.squareup.javapoet.ClassName;
import com.squareup.javapoet.FieldSpec;

import javax.lang.model.element.Modifier;

/**
 * 类型常量
 */
public interface ClassConstants {
    String JDBC_TEMPLATE = "jdbcTemplate";

    ClassName JDBC_TEMPLATE_CLASS = ClassName.get("org.springframework.jdbc.core", "JdbcTemplate");
    ClassName ROW_MAPPER_CLASS = ClassName.get("org.springframework.jdbc.core", "RowMapper");
    ClassName AUTOWIRED_CLASS = ClassName.get("org.springframework.beans.factory.annotation", "Autowired");

    FieldSpec fieldSpec = FieldSpec.builder(JDBC_TEMPLATE_CLASS, JDBC_TEMPLATE, Modifier.PRIVATE)
        .addAnnotation(AUTOWIRED_CLASS)
        .build();
}
